|
Eclipse Platform Pre-release 3.0 |
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.eclipse.core.runtime.PlatformObject
org.eclipse.core.internal.jobs.InternalJob
org.eclipse.core.runtime.jobs.Job
org.eclipse.ui.progress.UIJob
Field Summary |
Fields inherited from class org.eclipse.core.runtime.jobs.Job |
ASYNC_FINISH, BUILD, DECORATE, INTERACTIVE, LONG, NONE, RUNNING, SHORT, SLEEPING, WAITING |
Fields inherited from class org.eclipse.core.internal.jobs.InternalJob |
BLOCKED |
Constructor Summary | |
UIJob(Display jobDisplay,
String name)
Create a new instance of the receiver with the supplied Display. |
|
UIJob(String name)
Create a new instance of the receiver with the supplied name. |
Method Summary | |
static IStatus |
errorStatus(Throwable exception)
Convenience method to return a status for an exception. |
Display |
getDisplay()
Returns the display for use by the receiver. |
IStatus |
run(IProgressMonitor monitor)
Executes the current job. |
abstract IStatus |
runInUIThread(IProgressMonitor monitor)
Run the job in the UI Thread. |
void |
setDisplay(Display runDisplay)
Sets the display to execute the asyncExec in. |
Methods inherited from class org.eclipse.core.runtime.jobs.Job |
addJobChangeListener, belongsTo, cancel, done, getName, getPriority, getResult, getRule, getState, getThread, isSystem, join, removeJobChangeListener, schedule, schedule, setName, setPriority, setRule, setSystem, setThread, shouldRun, shouldSchedule, sleep, wakeUp |
Methods inherited from class org.eclipse.core.internal.jobs.InternalJob |
compareTo, toString |
Methods inherited from class org.eclipse.core.runtime.PlatformObject |
getAdapter |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Methods inherited from interface org.eclipse.core.runtime.IAdaptable |
getAdapter |
Constructor Detail |
public UIJob(String name)
name
- the job namepublic UIJob(Display jobDisplay, String name)
jobDisplay
- the displayname
- the job nameMethod Detail |
public static IStatus errorStatus(Throwable exception)
exception
-
public final IStatus run(IProgressMonitor monitor)
Job
The provided monitor can be used to report progress and respond to cancellation. If the progress monitor has been cancelled, the job should finish its execution at the earliest convenience.
This method must not be called directly by clients. Clients should call
schedule
, which will in turn cause this method to be called.
Jobs can optionally finish their execution asynchronously (in another thread) by
returning a result status of Job.ASYNC_FINISH
. Jobs that finish
asynchronously must indicate when they are finished by calling
the method Job.done
.
run
in class Job
monitor
- the monitor to be used for reporting progress, or
null
if progress monitoring is not required.
Job.ASYNC_FINISH
,
Job.done(org.eclipse.core.runtime.IStatus)
public abstract IStatus runInUIThread(IProgressMonitor monitor)
monitor
-
public void setDisplay(Display runDisplay)
runDisplay
- Displaypublic Display getDisplay()
null
.
|
Eclipse Platform Pre-release 3.0 |
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |